3. NetBIOS Enumeration

NetBIOS(Network Basic Input Output System) was developed as an API(Application Programming Interface) which allows communication between applications such as a printer or other computer in a LAN.

This service uses a unique 16 ASCII character string in order to identify the network devices over TCP/IP.
First 15 characters - identify Devices
16th character - identify the service

9eae9da05755011cead35c931eb55019.png

Workgroup: It is a peer-to-peer network for a maximum of 10 computers in the same LAN or subnet. It has no Centralized Administration, which means no computer has control over another computer. Each user controls the resources and security locally on their system.

Domain: It is a client/server network for up to 2000 computers anywhere in the world. The administrator manages the domain and its users and resources. A user with an account on the domain can log onto any computer system, without having the account on that computer.

71396ea46a9a7d469579961d0864c774.png

1302557869105397916a0b14eb13c7c9.png


Enumeration

  1. nbstat command can be used to display NetBIOS information like NetBIOS name tables,name cache etc.
    It is for Windows only.On linux nmblookup can be used.

nbstat -A [TARGET]
Display NetBIOS name table,MAC address information

861319490bd7f9711b5357ead83540ad.png

9e6a6e7eb6e8621b926b3beab80b0a5e.png

  1. netview - This utility is used to enumerate shared resources and displays a list of domains, computers, or resources that are being shared by the specified computer.
    It also works on Windows only.

net view [\\ComputerName or IP [/CACHE] | [/ALL] | /DOMAIN[:DomainName]]

771cb599b9bb55a709161438039139cf.png

43dd2e4bc329dd8c632332513ca5ec55.png


Enumerating NetBIOS in Metasploitable2

  1. Nmap Scripts

61250d6138efc09892c0c5d75723529a.png

T - TCP Connect scan
U - UDP scan
V - Version Detection

c7d1ce160a746eeae76f276ceacac84f.png

NetBIOS Suffixes
NetBIOS End Character (endchar)= the 16th character of a NetBIOS name.

For unique names:
00: Workstation Service (workstation name)
03: Windows Messenger service
06: Remote Access Service
20: File Service (also called Host Record)
1D: Master Browser

For group names:
00: Workstation Service (workgroup/domain name)
1E: Browser Service Elections
01:Master Browser (represented with MSBOWSE)

Computer Browser Service is a feature of Microsoft Windows to let users easily browse and locate shared resources in neighboring computers. This is done by aggregating the information in a single computer "Browse Master".

A server’s browser role is defined dynamically with periodic elections .
All the computers on a LAN hold an “election”. This election depends on a number of factors, all the computers get together and vote on who will be the Master Browser on the LAN.
Once a computer is elected, it will keep track of what machines are connected to the LAN.

057f6a75d1587941182dbf4a9065e35d.png

  1. Metasploit modules

034669448ef9f2aa854f0b83d3b68df2.png

Note:

Using nmblookup on Metasploitable2
NetBIOS(Network Basic Input Output System) was developed as an API(Application Programming Interface) which allows communication between applications such as a printer or other computer in a LAN.

This service uses a unique 16 ASCII character string in order to identify the network devices over TCP/IP.
First 15 characters - identify Devices
16th character - identify the service

9eae9da05755011cead35c931eb55019.png

Workgroup: It is a peer-to-peer network for a maximum of 10 computers in the same LAN or subnet. It has no Centralized Administration, which means no computer has control over another computer. Each user controls the resources and security locally on their system.

Domain: It is a client/server network for up to 2000 computers anywhere in the world. The administrator manages the domain and its users and resources. A user with an account on the domain can log onto any computer system, without having the account on that computer.

71396ea46a9a7d469579961d0864c774.png

1302557869105397916a0b14eb13c7c9.png


Enumeration

  1. nbstat command can be used to display NetBIOS information like NetBIOS name tables,name cache etc.
    It is for Windows only.On linux nmblookup can be used.

nbstat -A [TARGET]
Display NetBIOS name table,MAC address information

861319490bd7f9711b5357ead83540ad.png

9e6a6e7eb6e8621b926b3beab80b0a5e.png

  1. netview - This utility is used to enumerate shared resources and displays a list of domains, computers, or resources that are being shared by the specified computer.
    It also works on Windows only.

net view [\\ComputerName or IP [/CACHE] | [/ALL] | /DOMAIN[:DomainName]]

771cb599b9bb55a709161438039139cf.png

43dd2e4bc329dd8c632332513ca5ec55.png


Enumerating NetBIOS in Metasploitable2

  1. Nmap Scripts

61250d6138efc09892c0c5d75723529a.png

T - TCP Connect scan
U - UDP scan
V - Version Detection

c7d1ce160a746eeae76f276ceacac84f.png

NetBIOS Suffixes
NetBIOS End Character (endchar)= the 16th character of a NetBIOS name.

For unique names:
00: Workstation Service (workstation name)
03: Windows Messenger service
06: Remote Access Service
20: File Service (also called Host Record)
1D: Master Browser

For group names:
00: Workstation Service (workgroup/domain name)
1E: Browser Service Elections
01:Master Browser (represented with MSBOWSE)

Computer Browser Service is a feature of Microsoft Windows to let users easily browse and locate shared resources in neighboring computers. This is done by aggregating the information in a single computer "Browse Master".

A server’s browser role is defined dynamically with periodic elections .
All the computers on a LAN hold an “election”. This election depends on a number of factors, all the computers get together and vote on who will be the Master Browser on the LAN.
Once a computer is elected, it will keep track of what machines are connected to the LAN.

057f6a75d1587941182dbf4a9065e35d.png

  1. Metasploit modules

034669448ef9f2aa854f0b83d3b68df2.png

Note:

Using nmblookup on Metasploitable2

NetBIOS(Network Basic Input Output System) was developed as an API(Application Programming Interface) which allows communication between applications such as a printer or other computer in a LAN.

This service uses a unique 16 ASCII character string in order to identify the network devices over TCP/IP.
First 15 characters - identify Devices
16th character - identify the service

9eae9da05755011cead35c931eb55019.png

Workgroup: It is a peer-to-peer network for a maximum of 10 computers in the same LAN or subnet. It has no Centralized Administration, which means no computer has control over another computer. Each user controls the resources and security locally on their system.

Domain: It is a client/server network for up to 2000 computers anywhere in the world. The administrator manages the domain and its users and resources. A user with an account on the domain can log onto any computer system, without having the account on that computer.

71396ea46a9a7d469579961d0864c774.png

1302557869105397916a0b14eb13c7c9.png


Enumeration

  1. nbstat command can be used to display NetBIOS information like NetBIOS name tables,name cache etc.
    It is for Windows only.On linux nmblookup can be used.

nbstat -A [TARGET]
Display NetBIOS name table,MAC address information

861319490bd7f9711b5357ead83540ad.png

9e6a6e7eb6e8621b926b3beab80b0a5e.png

  1. netview - This utility is used to enumerate shared resources and displays a list of domains, computers, or resources that are being shared by the specified computer.
    It also works on Windows only.

net view [\\ComputerName or IP [/CACHE] | [/ALL] | /DOMAIN[:DomainName]]

771cb599b9bb55a709161438039139cf.png

43dd2e4bc329dd8c632332513ca5ec55.png


Enumerating NetBIOS in Metasploitable2

  1. Nmap Scripts

61250d6138efc09892c0c5d75723529a.png

T - TCP Connect scan
U - UDP scan
V - Version Detection

c7d1ce160a746eeae76f276ceacac84f.png

NetBIOS Suffixes
NetBIOS End Character (endchar)= the 16th character of a NetBIOS name.

For unique names:
00: Workstation Service (workstation name)
03: Windows Messenger service
06: Remote Access Service
20: File Service (also called Host Record)
1D: Master Browser

For group names:
00: Workstation Service (workgroup/domain name)
1E: Browser Service Elections
01:Master Browser (represented with MSBOWSE)

Computer Browser Service is a feature of Microsoft Windows to let users easily browse and locate shared resources in neighboring computers. This is done by aggregating the information in a single computer "Browse Master".

A server’s browser role is defined dynamically with periodic elections .
All the computers on a LAN hold an “election”. This election depends on a number of factors, all the computers get together and vote on who will be the Master Browser on the LAN.
Once a computer is elected, it will keep track of what machines are connected to the LAN.

057f6a75d1587941182dbf4a9065e35d.png

  1. Metasploit modules

034669448ef9f2aa854f0b83d3b68df2.png

Note:

Using nmblookup on Metasploitable2

da451e62ea643103719f8c4925765de8.png

As you can see, we already got some of this information in our enumeration.